
package com.audi.activiey.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;
import org.hibernate.annotations.GenericGenerator;
import org.hibernate.validator.constraints.Length;

@Entity
@Table(name = "tbl_activity_info")
public class ActivityInfo implements java.io.Serializable{
    
	private static final long serialVersionUID = 5454155825314635342L;
	
	
    /**
     * activityId       db_column: activity_id 
     */ 	
	
	private Long activityId;
    /**
     * title       db_column: title 
     */ 	
	//@Length(max=512)
	private java.lang.String title;
    /**
     * catalogId       db_column: catalog_id 
     */ 	
	
	private Long catalogId;
    /**
     * tag       db_column: tag 
     */ 	
	//@Length(max=256)
	private java.lang.String tag;
    /**
     * startTime       db_column: start_time 
     */ 	
	
	private java.util.Date startTime;
    /**
     * endTime       db_column: end_time 
     */ 	
	
	private java.util.Date endTime;
    /**
     * deadTime       db_column: dead_time 
     */ 	
	
	private java.util.Date deadTime;
    /**
     * status       db_column: status 
     */ 	
	
	private Long status;
    /**
     * logo       db_column: logo 
     */ 	
	//@Length(max=128)
	private java.lang.String logo;
    /**
     * provinceId       db_column: province_id 
     */ 	
	
	private Long provinceId;
    /**
     * cityId       db_column: city_id 
     */ 	
	
	private Long cityId;
    /**
     * address       db_column: address 
     */ 	
	//@Length(max=4000)
	private java.lang.String address;
    /**
     * permissionSet       db_column: permission_set 
     */ 	
	
	private Long permissionSet;
    /**
     * wayOfContact       db_column: way_of_contact 
     */ 	
	//@Length(max=4000)
	private java.lang.String wayOfContact;
    /**
     * descn       db_column: descn 
     */ 	
	//@Length(max=4000)
	private java.lang.String descn;
    /**
     * userId       db_column: user_id 
     */ 	
	
	private Long userId;
    /**
     * nickName       db_column: nick_name 
     */ 	
	//@Length(max=64)
	private java.lang.String nickName;
    /**
     * limitNum       db_column: limit_num 
     */ 	
	
	private Long limitNum;
    /**
     * joinNum       db_column: join_num 
     */ 	
	
	private Long joinNum;
    /**
     * viewNum       db_column: view_num 
     */ 	
	
	private Long viewNum;
    /**
     * collectNum       db_column: collect_num 
     */ 	
	
	private Long collectNum;
    /**
     * isShare       db_column: is_share 
     */ 	
	
	private Long isShare;
    /**
     * shareSum       db_column: share_sum 
     */ 	
	
	private Long shareSum;
    /**
     * isComment       db_column: is_comment 
     */ 	
	
	private Long isComment;
    /**
     * commentNum       db_column: comment_num 
     */ 	
	
	private Long commentNum;
    /**
     * top       db_column: top 
     */ 	
	
	private Long top;
    /**
     * topTime       db_column: top_time 
     */ 	
	
	private java.util.Date topTime;
    /**
     * ip       db_column: ip 
     */ 	
	//@Length(max=128)
	private java.lang.String ip;
    /**
     * modifyTime       db_column: modify_time 
     */ 	
	
	private java.util.Date modifyTime;
    /**
     * createTime       db_column: create_time 
     */ 	
	
	private java.util.Date createTime;
	//columns END


	public ActivityInfo(){
	}

	public ActivityInfo(
		Long activityId
	){
		this.activityId = activityId;
	}

	

	public void setActivityId(Long value) {
		this.activityId = value;
	}
	
	@Id
	//@SequenceGenerator(name="activity_info_SEQ",sequenceName="seq_activity_info")
    //@GeneratedValue(strategy=GenerationType.SEQUENCE,generator="activity_info_SEQ") 
	@GenericGenerator(name="custom-id", strategy = "identity")
    @GeneratedValue(generator="custom-id")
	@Column(name = "activity_id")
	public Long getActivityId() {
		return this.activityId;
	}
	
	@Column(name = "title",length=512)
	public java.lang.String getTitle() {
		return this.title;
	}
	
	public void setTitle(java.lang.String value) {
		this.title = value;
	}
	
	@Column(name = "catalog_id")
	public Long getCatalogId() {
		return this.catalogId;
	}
	
	public void setCatalogId(Long value) {
		this.catalogId = value;
	}
	
	@Column(name = "tag",length=256)
	public java.lang.String getTag() {
		return this.tag;
	}
	
	public void setTag(java.lang.String value) {
		this.tag = value;
	}
	
	
	@Column(name = "start_time")
	public java.util.Date getStartTime() {
		return this.startTime;
	}
	
	public void setStartTime(java.util.Date value) {
		this.startTime = value;
	}
	
	
	
	@Column(name = "end_time")
	public java.util.Date getEndTime() {
		return this.endTime;
	}
	
	public void setEndTime(java.util.Date value) {
		this.endTime = value;
	}
	
	
	@Column(name = "dead_time")
	public java.util.Date getDeadTime() {
		return this.deadTime;
	}
	
	public void setDeadTime(java.util.Date value) {
		this.deadTime = value;
	}
	
	@Column(name = "status")
	public Long getStatus() {
		return this.status;
	}
	
	public void setStatus(Long value) {
		this.status = value;
	}
	
	@Column(name = "logo",length=128)
	public java.lang.String getLogo() {
		return this.logo;
	}
	
	public void setLogo(java.lang.String value) {
		this.logo = value;
	}
	
	@Column(name = "province_id")
	public Long getProvinceId() {
		return this.provinceId;
	}
	
	public void setProvinceId(Long value) {
		this.provinceId = value;
	}
	
	@Column(name = "city_id")
	public Long getCityId() {
		return this.cityId;
	}
	
	public void setCityId(Long value) {
		this.cityId = value;
	}
	
	@Column(name = "address",length=4000)
	public java.lang.String getAddress() {
		return this.address;
	}
	
	public void setAddress(java.lang.String value) {
		this.address = value;
	}
	
	@Column(name = "permission_set")
	public Long getPermissionSet() {
		return this.permissionSet;
	}
	
	public void setPermissionSet(Long value) {
		this.permissionSet = value;
	}
	
	@Column(name = "way_of_contact",length=4000)
	public java.lang.String getWayOfContact() {
		return this.wayOfContact;
	}
	
	public void setWayOfContact(java.lang.String value) {
		this.wayOfContact = value;
	}
	
	@Column(name = "descn",length=4000)
	public java.lang.String getDescn() {
		return this.descn;
	}
	
	public void setDescn(java.lang.String value) {
		this.descn = value;
	}
	
	@Column(name = "user_id")
	public Long getUserId() {
		return this.userId;
	}
	
	public void setUserId(Long value) {
		this.userId = value;
	}
	
	@Column(name = "nick_name",length=64)
	public java.lang.String getNickName() {
		return this.nickName;
	}
	
	public void setNickName(java.lang.String value) {
		this.nickName = value;
	}
	
	@Column(name = "limit_num")
	public Long getLimitNum() {
		return this.limitNum;
	}
	
	public void setLimitNum(Long value) {
		this.limitNum = value;
	}
	
	@Column(name = "join_num")
	public Long getJoinNum() {
		return this.joinNum;
	}
	
	public void setJoinNum(Long value) {
		this.joinNum = value;
	}
	
	@Column(name = "view_num")
	public Long getViewNum() {
		return this.viewNum;
	}
	
	public void setViewNum(Long value) {
		this.viewNum = value;
	}
	
	@Column(name = "collect_num")
	public Long getCollectNum() {
		return this.collectNum;
	}
	
	public void setCollectNum(Long value) {
		this.collectNum = value;
	}
	
	@Column(name = "is_share")
	public Long getIsShare() {
		return this.isShare;
	}
	
	public void setIsShare(Long value) {
		this.isShare = value;
	}
	
	@Column(name = "share_sum")
	public Long getShareSum() {
		return this.shareSum;
	}
	
	public void setShareSum(Long value) {
		this.shareSum = value;
	}
	
	@Column(name = "is_comment")
	public Long getIsComment() {
		return this.isComment;
	}
	
	public void setIsComment(Long value) {
		this.isComment = value;
	}
	
	@Column(name = "comment_num")
	public Long getCommentNum() {
		return this.commentNum;
	}
	
	public void setCommentNum(Long value) {
		this.commentNum = value;
	}
	
	@Column(name = "top")
	public Long getTop() {
		return this.top;
	}
	
	public void setTop(Long value) {
		this.top = value;
	}
	
	
	@Column(name = "top_time")
	public java.util.Date getTopTime() {
		return this.topTime;
	}
	
	public void setTopTime(java.util.Date value) {
		this.topTime = value;
	}
	
	@Column(name = "ip",length=128)
	public java.lang.String getIp() {
		return this.ip;
	}
	
	public void setIp(java.lang.String value) {
		this.ip = value;
	}
	
	
	
	@Column(name = "modify_time")
	public java.util.Date getModifyTime() {
		return this.modifyTime;
	}
	
	public void setModifyTime(java.util.Date value) {
		this.modifyTime = value;
	}
	
	
	@Column(name = "create_time")
	public java.util.Date getCreateTime() {
		return this.createTime;
	}
	
	public void setCreateTime(java.util.Date value) {
		this.createTime = value;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("ActivityId",getActivityId())
			.append("Title",getTitle())
			.append("CatalogId",getCatalogId())
			.append("Tag",getTag())
			.append("StartTime",getStartTime())
			.append("EndTime",getEndTime())
			.append("DeadTime",getDeadTime())
			.append("Status",getStatus())
			.append("Logo",getLogo())
			.append("ProvinceId",getProvinceId())
			.append("CityId",getCityId())
			.append("Address",getAddress())
			.append("PermissionSet",getPermissionSet())
			.append("WayOfContact",getWayOfContact())
			.append("Descn",getDescn())
			.append("UserId",getUserId())
			.append("NickName",getNickName())
			.append("LimitNum",getLimitNum())
			.append("JoinNum",getJoinNum())
			.append("ViewNum",getViewNum())
			.append("CollectNum",getCollectNum())
			.append("IsShare",getIsShare())
			.append("ShareSum",getShareSum())
			.append("IsComment",getIsComment())
			.append("CommentNum",getCommentNum())
			.append("Top",getTop())
			.append("TopTime",getTopTime())
			.append("Ip",getIp())
			.append("ModifyTime",getModifyTime())
			.append("CreateTime",getCreateTime())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getActivityId())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof ActivityInfo == false) return false;
		if(this == obj) return true;
		ActivityInfo other = (ActivityInfo)obj;
		return new EqualsBuilder()
			.append(getActivityId(),other.getActivityId())
			.isEquals();
	}
}

